package game;

import java.awt.Dimension;
import java.awt.image.BufferedImage;

import util.reflection.Reflection;
import util.resources.ResourceManager;
import util.resources.XMLReader;

import com.golden.gamedev.Game;
import com.golden.gamedev.object.Background;
import com.golden.gamedev.object.background.ImageBackground;


public class GameManager {

    private Game myGame;
    private Background[] myBackgrounds;
    private XMLReader myXMLReader;
    private final String BADASSKITTEH = "src/resources/Kitty.xml";
    private final String RESOURCES = "src/resources/game.properties";
    private ResourceManager myResource;
    
    public GameManager(Game game)
    {
        myGame = game;
        myResource = ResourceManager.getInstance();
        myXMLReader = new XMLReader();
//        myResource.addResourcesFromFile(RESOURCES);
        this.createLevels();
    }
    
    /**
     * Reads in the different levels for the game. Each level has a different background.
     */
    private void createLevels()
    {
        String[] test = myXMLReader.readFile(BADASSKITTEH, "Level1");
//        Reflection.createInstance(test[0]);
        ImageBackground t = new ImageBackground(myGame.getImage(test[0]));
    }
   
}
